﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Uniforax.Core.Common
{
    public class CampDataValueChangedEventArgs
    {
        public string PropertyName { get; set; }
        public bool NewValue { get; set; }
    }

    public class CampData
    {
        public event EventHandler<CampDataValueChangedEventArgs> OnValueChanged;

        public virtual void SetValue(string propertyName, bool newValue)
        {

        }

        protected void RaiseValueChanged(string propertyName, bool value)
        {
            OnValueChanged?.Invoke(this, new CampDataValueChangedEventArgs()
            {
                NewValue = value,
                PropertyName = propertyName
            });
        }

        public virtual bool GetValue(string propertyName) 
        {
            return false;
        }
    }


}
